
<template>
<div class="goodsdesc-container">
        <h3>{{ info.title }}</h3>
        <hr>
        <div class="content" v-html="info.content">

        </div>
</div>
</template>    
<script>
export default{
    data(){
        return {
            info:{}
        }
    },
    created(){
        this.getGoodsDesc();
    },
    methods:{
        getGoodsDesc(){
            this.$http.get("http://127.0.0.1/vue.js/项目练习/api/json/goodsDesc.json").then(result =>{
                this.info = result.body.message[0];
            })
        }
    }
}
</script>
<style lang="less" scoped>
 .goodsdesc-containe{
     padding: 0 5px;
     h3{
         font-size: 16px;
         color: blue;
         text-align: center;
         margin: 15xp 0px;
     }
     .conetent{
         img{
             width: 100%;
         }
     }
 }
</style> 